﻿using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using MaxLeaf.Platform.DataContract;
using CommonsLib.DB;
using MaxLeaf.Platform.DALImplementation;
using MaxLeaf.Platform.Functions;
using CommonsLib.Utility;
using MaxLeaf.Platform.Commons;

namespace MaxLeaf.Platform.BLLImplementation
{
    public class poReqDtlBLL : BaseBLL
    {
        
        public override string FinterIDFields
        {
            get
            {
                return string.Format("{0},{1}", "DtlID", (int)FinterIDType.poReqDtl);
            }
        }


        internal List<int> GetUnpostKeys(int intHdrID)
        {
            using (DBAccess dbcon = DataFunc.GetDBAccessByDataModelType(typeof(poReqDtlDataModel)))
            {
                return ((poReqDtlDAL)this.CurrentDAL).GetUnpostKeys(dbcon, intHdrID);
            }
        }


        internal void SetPosted(DBAccess dbcon, int intKey, int intOrderHdrId, int intOrderDtlId)
        {
            ((poReqDtlDAL)this.CurrentDAL).SetPosted(dbcon, intKey, intOrderHdrId, intOrderDtlId);
        }
    }
}
